/***
 * 添加班级
 * ***/
SPA_RESOLVE_INIT = function(transition) {
    var html = '<div class="right-list-box addhomework-box mt-20 pb-150 magin-auto">\n' +
        '<div class="items">\n' +
        '<label>班级名称：</label>\n' +
        '<input type="text" class="t t1 rad-3 ml-10 f-14" />\n' +
        '</div>    \n' +
        '<div class="items">\n' +
        '<label>学生列表：</label>\n' +
        '<select class="rad-3 t t3 ml-10 f-14" id="">\n' +
        '<option>--请选择--</option>\n' +
        '<option value="">文件导入</option>\n' +
        '        <option value="">自动添加</option>          \n' +
        '</select>\n' +
        '<span class="filetype">支持格式：.doc/.csv/.xlsx</span>\n' +
        '</div>        \n' +
        '\n' +
        '\n' +
        '<div class="items thefile">\n' +
        '<label>文件：</label>\n' +
        '<input type="text" id="filename" class="t t3 rad-3 ml-10 f-14 filename" disabled/>\n' +
        '<div class="upload-box relative bg-169 text-center c-fff f-14 rad-3 ml-10">\n' +
        '选择文件<input type="file" name="files" id="fileinputs" onchange="fileinput(this)" class="absolute pointer fileinputs"/>\n' +
        '</div>        \n' +
        '</div>   \n' +
        '\n' +
        '\n' +
        '<div class="items hide">\n' +
        '<label>学号：</label>\n' +
        '<input type="text" class="t t3 rad-3 ml-10 f-14" />\n' +
        '</div> \n' +
        '\n' +
        '<div class="items mt-35">\n' +
        '<label></label>\n' +
        '<a href="javascript:;" class="btn-t c-fff f-14 bg-169 rad-3 ml-10 text-center">导入</a>\n' +
        '</div>\n' +
        '</div> ';

    getHref_path();
    $(".menu ul").hide();
    $(".menu ul").eq(1).show();
    document.getElementById("ui-right-content").innerHTML = html;


}

function fileinput(obj) {
    filedir=$(obj).val()
    filenames=filedir.split(/[/\\]/)
    filename=filenames[filenames.length-1]
    $(obj).closest(".filename").val(filename)
}